﻿using System;
using System.Collections.Generic;
using System.Text;
using WordService.Model;

namespace WordService.Data.IDAL
{
    /// <summary>
    /// 关键字的数据层接口
    /// </summary>
    public interface IKeywordDAL
    {
        /// <summary>
        /// 插入关键字接口
        /// </summary>
        /// <param name="name">关键字名称</param>
        /// <param name="count">关键字本文出现次数</param>
        /// <param name="rightRate">关键字权值</param>
        /// <param name="articleID">对应的文章ID</param>
        /// <param name="totalCount">关键字总共出现的次数</param>
        /// <returns>关键字插入的ID</returns>
        Int64 InsertKeyword(String name, Int64 count, decimal rightRate, Int64 articleID, Int64 totalCount);
        ///// <summary>
        ///// 保存关键字接口【添加、更新】
        ///// </summary>
        ///// <param name="name">关键字名称</param>
        ///// <param name="count">关键字本文出现次数</param>
        ///// <param name="rightRate">关键字权值</param>
        ///// <param name="articleID">对应的文章ID</param>
        ///// <param name="totalCount">关键字总共出现的次数</param>
        ///// <returns>关键字插入的ID</returns>
        //Int64 SaveKeyword(String name, Int64 count, decimal rightRate, Int64 articleID, Int64 totalCount);
        ///// <summary>
        ///// 更新关键字接口
        ///// </summary>
        ///// <param name="name">关键字名称</param>
        ///// <param name="count">关键字本文出现次数</param>
        ///// <param name="rightRate">关键字权值</param>
        ///// <param name="articleID">对应的文章ID</param>
        ///// <param name="totalCount">关键字总共出现的次数</param>
        ///// <param name="ID">关键字的ID号</param>
        ///// <returns>返回关键字插入的ID</returns>
        //Int64 UpdateKeyword(String name, Int64 count, decimal rightRate, Int64 articleID, Int64 totalCount, Int64 ID);
        /// <summary>
        /// 查询关键字列表需要的内容
        /// </summary>
        /// <param name="authorName">作者名</param>
        /// <param name="insName">机构名</param>
        /// <param name="frequency">频次录入</param>
        /// <param name="year">输入年份</param>
        /// <returns></returns>
        IList<Keyword> QueryByCondition(String authorName, String insName, Int64 frequency, String year);
    }
}
